$(function () {
    $("body").on('click','.addBigSubject',function () {//添加专业
        var list = $(".parent-subject");
        var parentIds = '';
        if(list!=null && list.length>0){
            parentIds = list.map(function () {
                return $(this).data('id');
            }).get().join(",");
        }
        window.location.href = baseloaction +'/mobile/uc/academic/getSubjectParent?parentIds='+parentIds;
    }).on('click','.addSmallSubject',function () {//添加科目
        var parentId = $(this).data("parent");
        var childList = $(".parent-box-"+parentId);
        var childIds = '';
        if(childList !=null && childList.length >0){
            childIds = childList.map(function () {
                return $(this).data('id');
            }).get().join(",");
        }
        window.location.href = baseloaction +'/mobile/uc/academic/querySubjectByParentIds?parentId='+parentId+"&childIds="+childIds;
    });
});